/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package org.cellstore.entidad;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Embeddable;

/**
 *
 * @author paescobar
 */
@Embeddable
public class TbSystparPK implements Serializable {
    @Basic(optional = false)
    @Column(name = "cCodMod")
    private String cCodMod;
    @Basic(optional = false)
    @Column(name = "cCodTab")
    private String cCodTab;
    @Basic(optional = false)
    @Column(name = "cCodigo")
    private String cCodigo;

    public TbSystparPK() {
    }

    public TbSystparPK(String cCodMod, String cCodTab, String cCodigo) {
        this.cCodMod = cCodMod;
        this.cCodTab = cCodTab;
        this.cCodigo = cCodigo;
    }

    public String getCCodMod() {
        return cCodMod;
    }

    public void setCCodMod(String cCodMod) {
        this.cCodMod = cCodMod;
    }

    public String getCCodTab() {
        return cCodTab;
    }

    public void setCCodTab(String cCodTab) {
        this.cCodTab = cCodTab;
    }

    public String getCCodigo() {
        return cCodigo;
    }

    public void setCCodigo(String cCodigo) {
        this.cCodigo = cCodigo;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (cCodMod != null ? cCodMod.hashCode() : 0);
        hash += (cCodTab != null ? cCodTab.hashCode() : 0);
        hash += (cCodigo != null ? cCodigo.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof TbSystparPK)) {
            return false;
        }
        TbSystparPK other = (TbSystparPK) object;
        if ((this.cCodMod == null && other.cCodMod != null) || (this.cCodMod != null && !this.cCodMod.equals(other.cCodMod))) {
            return false;
        }
        if ((this.cCodTab == null && other.cCodTab != null) || (this.cCodTab != null && !this.cCodTab.equals(other.cCodTab))) {
            return false;
        }
        if ((this.cCodigo == null && other.cCodigo != null) || (this.cCodigo != null && !this.cCodigo.equals(other.cCodigo))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "org.cellstore.entidad.TbSystparPK[ cCodMod=" + cCodMod + ", cCodTab=" + cCodTab + ", cCodigo=" + cCodigo + " ]";
    }
    
}
